package com.dsz.controller;

import java.util.Map;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import com.dsz.service.UsersService;

@RestController
@CrossOrigin
public class LoginController {

	@Autowired
	private UsersService us;
	
	@RequestMapping("/login")
	public Map<String, Object> login(String loginname , String password){
		return us.login(loginname,password);
	}
	
	@RequestMapping("/testToken")
	public Boolean testToken() {
		return true;
	}
	
	
}
